class SuperType {
  constructor(str) {
    this.str = str ?? "none";
    this.arr = [1, 2, 3];
    this.fn = () => console.log(1);
  }
}
const superType = new SuperType("superType");
console.log(superType);

class SubType extends SuperType{
  constructor(num){
    super()
    this.num = num;
  }
}

/**
 * 优点：
 * 缺点：
 */

const subType = new SubType();
console.log(subType);
